const mongoose = require('./db')
const Schema = mongoose.Schema
const TokenSchema = new Schema({
    // 标题
    title: {
        type: String,
        required: true
    },
    // parent: {
    //     type: String,
    //     required: false
    // },
    // 行业类别：建筑工程 市政公用工程 水利水电工程 公路工程，二进制掩码表示，如 1000 表示模版仅支持建筑工程
    subjectType: {
        type: Number,
        required: false,
        default: 8
    },
    // 内容
    content: {
        type: String,
        required: true
    },
    // 作者
    author: {
        type: String,
        required: true
    },
    // 审核意见
    audit: {
        type: String,
        required: false
    },
    auditMills: {
        type: String,
        required: false
    },
    // 是否通过审核
    pass: {
        type: Boolean,
        required: true,
        default: false
    },
    timeMills: {
        type: String,
        required: true
    }
})

module.exports = DocModel_2 = mongoose.model('docs_2', TokenSchema)
